package com.panda.mall.order.info.service;


import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.panda.mall.common.mallOrder.dto.QueryOrderDto;
import com.panda.mall.common.mallOrder.entity.MallOrder;

import java.util.List;

/**
* @author tucy123
* @description 针对表【mall_order(订单信息表)】的数据库操作Service
* @createDate 2022-10-13 16:33:08
*/
public interface MallOrderService extends IService<MallOrder> {

    /**
     * 获取订单编号
     * @return
     */
    String generateOrderNumber();

    /**
     * 分页查询订单
     * @return
     */
    Page<MallOrder> listOrders(QueryOrderDto dto);

    /**
     * 查询订单
     * @return
     */
    List<MallOrder> queryOrders();

    /**
     * 按id查询订单
     * @param id
     * @return
     */
    MallOrder queryOrderById(Long id);

    /**
     * 新增订单
     * @param order
     * @return
     */
    Boolean saveOrder(MallOrder order);

    /**
     * 修改订单
     * @param order
     * @return
     */
    Boolean updateOrder(MallOrder order);

    /**
     * 删除订单
     * @param ids
     * @return
     */
    String deleteOrder(List<Long> ids);
}
